<%--
    Document   : find_job
    Created on : Feb 13, 2012, 11:26:33 PM
    Author     : Admin
--%>

<%@page import="java.util.Date"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">

<html>
    <head>
        <title>Recruitment</title>
        <link rel="shortcut icon" href="images/favicon.ico"/>
        <link href="css/dark.css" rel="stylesheet" type="text/css" />
        <link href="css/prettyPhoto.css" rel="stylesheet" type="text/css" />
        <link href="css/nivo-slider.css" rel="stylesheet" type="text/css" />
        <link href="css/noscript.css" rel="stylesheet" type="text/css" media="screen,all" id="noscript" />
        <!-- Stylesheets End //-->

        <!-- Javascript Start //-->

        <link rel="stylesheet" type="text/css" href="administrator/css/jquery-ui-1.8.17.custom.css" />
        <script type="text/javascript" src="administrator/js/jquery-1.7.1.min.js"></script>
        <script type="text/javascript" src="administrator/js/jquery-ui-1.8.17.custom.min.js"></script>
        <script type="text/javascript" src="administrator/js/jquery.tablesorter.pager.js"></script>
        <script type="text/javascript" src="administrator/js/tablesorter.js"></script>
        <script type="text/javascript" src="administrator/js/tablesorter_filter.js"></script>

        <script type="text/javascript">
            Cufon.replace('h1')('h2')('h3')('h4')('h5')('#myslidemenu a',{hover: 'true'})('#myslidemenu li li a',{textShadow: '1px 1px #ffffff',hover: 'true'})('a.button', {hover: 'true'})('.nivo-caption p');
        </script>

        <script type="text/javascript">

            jQuery(document).ready(function(){
                $("#tbEmp").tablesorter({debug:false, widgets: ['zebra'], sortList: [[0,0]]})
                .tablesorterPager({container: $("#pager")})
                .tablesorterFilter({filterContainer: $("#filter-box"),
                    filterClearContainer: $("#filter-clear-button"),
                    filterColumns: [0],
                    filterCaseSensitive: false
                });
            });

        </script>

        <style type="text/css">
            body{
                font-family: Arial, Tahoma, Verdana, sans-serif;
                font-size: 12px;
                color: #333;
            }
            table{background-image: url("./administrator/img/ws_datagrid_header.png");
                  background-repeat: no-repeat;
                  background-position: top center;
                  width: 620px;
            }
            table tr{
                line-height: 35px;
            }
            table td{text-align: left;}
            thead{
                display: table-header-group;
                text-align: left;
                border-color: inherit;
            }
            table thead tr{
                color: #005ca2;
                font-size: 12px;
                background-color: #E0E8F2;
                line-height: 36px;
            }
            table thead tr th{
                margin: 0px;
                padding: 0px;
                border-bottom: 2px solid #CED6E0;
                text-align: left;
                padding: 0px 5px;
            }
            .highlight{
                background-color: #F3F7FC;
            }
        </style>
    </head>
    <body>
        <div id="wrapper">
            <div id="topwrapper"></div>
            <div id="mainwrapper">
                <!-- Header Start -->
                <div id="header">
                    <div class="center">
                        <!-- Logo Start -->
                        <div id="logo">
                            <a href="index.jsp"><img src="./images/footerlogo.png" alt="logo" /></a>
                        </div>
                        <!-- Logo End -->

                        <div id="headerright">
                            <!-- Menu Navigation Start -->
                            <div id="mainmenu">
                                <div id="myslidemenu" class="jqueryslidemenu">
                                    <ul>
                                        <li><a href="index.jsp" class="selected">Home</a>
                                        </li>
                                        <li><a href="<c:choose>
                                                   <c:when test="${sessionScope.user == null}">login.jsp</c:when>
                                                   <c:otherwise>find_job.jsp</c:otherwise>
                                               </c:choose>">Find job</a>
                                        </li>
                                        <li><a href="<c:choose>
                                                   <c:when test="${sessionScope.user == null}">login.jsp</c:when>
                                                   <c:otherwise>profile.jsp</c:otherwise>
                                               </c:choose>">Profile</a>
                                        </li>
                                        <li><a href="<c:choose>
                                                   <c:when test="${sessionScope.user == null}">login.jsp</c:when>
                                                   <c:otherwise>my_career.jsp</c:otherwise>
                                               </c:choose>">My career</a>
                                        </li>
                                        
                                        <li><a href="login.jsp">Login</a>
                                        </li>

                                    </ul>
                                </div>
                            </div>
                            <!-- Menu Navigation End -->
                        </div>
                    </div>
                </div>
                <!-- Header End  -->

                <!-- Page Heading -->
                <div id="page-heading">
                    <img src="./images/page-heading1.jpg" alt="" />
                    <div class="heading-text">
                        <h3>Recruitment website.</h3>
                        <p>Hi ${sessionScope.user} !</p>
                        <p><a href="userLogout.do" style="text-decoration: underline; color: white;">logout</a></p>
                    </div>
                </div>
                <!-- Page Heading End -->
                <div class="clear"></div>

                <div class="center">

                    <!-- Left Sidebar -->
                    <div id="sidebar-left">
                        <div class="sidebar-left">
                            <div class="sidebartop"></div>
                            <div class="sidebarmain">
                                <div class="sidebarcontent">
                                    <h4 class="sidebarheading">Recruitment</h4>
                                    <ul class="sidelist">
                                        <jsp:useBean id="de" class="model.DepartmentModel"/>
                                        <c:forEach var="d" items="${de.sub2Department}">
                                            <li><a href="showJobByDep.do?task=dep&de=${d.departmentid}&name=${d.departmentname}" class="selected">${d.departmentname}</a>
                                            </li>
                                        </c:forEach>
                                    </ul>
                                </div>
                            </div>
                            <div class="sidebarbottom"></div><br>

                            <div class="sidebartop"></div>
                            <div class="sidebarmain">
                                <div class="sidebarcontent">
                                    <h4 class="sidebarheading">Salary</h4>
                                    <ul class="sidelist">
                                        <jsp:useBean id="sa" class="model.VacancyModel"/>
                                        <c:forEach var="d" items="${sa.distinctVacancy}">
                                            <li><a href="showJobByDep.do?task=salary&sa=${d.salary}">${d.salary}</a>
                                            </li>
                                        </c:forEach>
                                    </ul>
                                </div>
                            </div>
                            <div class="sidebarbottom"></div><br>

                            <div class="sidebartop"></div>
                            <div class="sidebarmain">
                                <div class="sidebarcontent">
                                    <h4 class="sidebarheading">Experience</h4>
                                    <ul class="sidelist">
                                        <jsp:useBean id="ye" class="model.VacancyModel"/>
                                        <c:forEach var="d" items="${ye.distinctYear}">
                                            <li><a href="showJobByDep.do?task=year&ye=${d.experience}">${d.experience}</a>
                                            </li>
                                        </c:forEach>
                                    </ul>
                                </div>
                            </div>
                            <div class="sidebarbottom"></div>
                        </div>

                    </div>
                    <!-- Left Sidebar End -->
                    <br><br>
                    <h4 style="text-decoration: underline;">* Find Job: ${param.name}</h4>
                    <br>
                    <form action="searchJobApply.do">
                        <p>Vacancy name: <input type="text" name="txtSearch"/> <input type="submit" value="Search"/></p>
                    </form>
                    <br>
                    <p style="color: #C92036;">${requestScope.error}</p>
                    <table id="tbEmp">
                        <thead>
                            <tr>
                                <th>Vacancy Title</th>
                                <th>Salary</th>
                                <th>Place</th>
                                <th>Experience</th>
                                <th>Close date</th>
                            </tr>
                        </thead>

                        <tbody>

                            <c:forEach var="v" items="${requestScope.vac}">
                                <tr class="highlight" style="border: 1px solid #aaaaaa;">
                                    <td><a href="user_viewJobDetail.do?vid=${v.vacancyID}" style="text-decoration: underline;">${v.vacancyTitle}</a></td>
                                    <td>${v.salary}</td>
                                    <td>${v.place}</td>
                                    <td>${v.experience}</td>
                                    <td>${v.closeDate}</td>
                                    <td><a href="applyJob.do?vid=${v.vacancyID}&aid=${sessionScope.aid}" style="color: #2e6e9e; text-decoration: underline;"><img src="images/tick.png" alt="" />Apply</a></td>
                                </tr>
                            </c:forEach>
                        </tbody>

                    </table>

                    <div id="pager" class="pager" style="color:#005CA2;font-weight:bolder;font-size:13px; margin-top: 20px; right: 250px;">
                        <form>
                            Page:
                            <input type="button" value="" class="first" style="background-image: url(./administrator/img/resultset_first.png); background-color: white; width: 20px;"/>
                            <input type="button" value="" class="prev" style="background-image: url(./administrator/img/resultset_previous.png); background-color: white; width: 20px;"/>
                            <input type="text" class="pagedisplay" readonly="true" style="width: 30px; height: 17px;"/>
                            <input type="button" value="" class="next" style="background-image: url(./administrator/img/resultset_next.png); background-color: white; width: 20px;"/>
                            <input type="button" value="" class="last" style="background-image: url(./administrator/img/resultset_last.png); background-color: white; width: 20px;"/>
                            Items per page:
                            <select class="pagesize">
                                <option value="5">5</option>
                                <option value="10" selected="selected">10</option>
                            </select>
                        </form>
                    </div>

                    <div class="maincontent-right">

                    </div>
                    <!-- Main Content End -->
                </div>
                <div class="clear"></div>
            </div>

            <!-- Footer Start -->
            <div id="bottomwrapper"></div>
            <div id="footer">

                <div class="clear"></div>

            </div>
            <!-- Footer End  -->
        </div>
    </body>
</html>
